Information-processing apparatus and information-processing method

ABSTRACT

Disclosed is an information-processing apparatus comprising: storage means for storing application programs and data files; calculating means for activating an application program stored in the storage means to carry out predetermined processing; media drive means for recording and playing back information into and from an external recording medium; and control means which controls the media-drive means and the storage means when the external recording medium for recording an application program is mounted on the media drive means so that: when the storage means includes a remaining free storage area with a size large enough for accommodating the application program recorded in the external recording medium, the application program recorded in the external recording medium is installed in the storage means; but when the storage means includes a remaining free storage area with a size not large enough for accommodating the application program recorded in the external recording medium, on the other hand, an application program or a data file stored in the storage means is saved to the external recording medium in order to allocate a free storage area in the storage means and then the application program recorded in the external recording medium is installed in the storage means.

BACKGROUND OF THE INVENTION

The present invention relates to an information-processing apparatus andan information-processing method. More particularly, the presentinvention relates to an information-processing apparatus and aninformation-processing method wherein an internal storage means isprovided and information is input from an external storage unit.

In addition, the present invention relates to processing to installapplication software in an information-processing apparatus and aninformation-processing method.

As an internal storage unit provided in an information-processingapparatus such as a personal computer and a PDA (Personal DigitalAssistant), there are a solid memory such as a RAM or a flash memory andan HDD (Hard-Disc Drive). As a storage unit external to theinformation-processing apparatus, it is possible to employ a variety ofportable recording media such as an optical disc, an optical-magneticdisc, a magnetic disc and a memory card.

By the way, a PDA apparatus or the like may activate applicationsoftware and make an access to a data file of a database. Theapplication software, the data file or the database may be stored in anexternal storage unit. In some cases, the application software, the datafile or the database must be once transferred from an external storageunit to an internal storage unit.

When activating application software and making an access to a data fileor a database, such an information-processing apparatus forms a judgmentas to whether the application software, the data file or the databaseare stored in the internal or external storage unit. Theinformation-processing apparatus carries out an operation according tothe outcome of the judgment. In order to activate application softwarestored in an external storage unit such as a memory card, for example,the user first carries out an operation to request that the applicationsoftware be loaded from the memory card. After the application softwarehas been loaded, it is necessary for the user to carry out an operationto activate the loaded software.

The operations are cumbersome for the user. In addition, since the usermust always know whether the target information is stored in theinternal or external storage unit, the operations are not simple either.Thus, the information-processing apparatus cannot be said to offer goodoperatability.

Assume that activated application software uses a data file or adatabase relevant to the software. In this case, in order to open thedata file, it is necessary for the user to carry out an operation tospecify a location to be searched for the data file or specify a file tobe actually used. For example, the user needs to specify a drive name, adirectory name or a file name.

For the purpose described above, however, the user must know thelocation at which the data file or other information to be used isrecorded. The user must form a judgment as to whether the data file orthe other information is stored in an internal storage unit or anexternal storage unit such as a memory card and then carry out anoperation according to the outcome of the judgment.

In addition, in the case of a portable and compactinformation-processing apparatus such as a PDA, the size of the internalstorage unit is unavoidably limited. Thus, when an application programis installed in the internal storage unit, the storage area becomes fullin many cases.

When the user wants to further add (or install) a new applicationprogram in such a circumstance, the user needs to delete or save analready installed program or an already installed data file in anotherstorage medium in order to secure a storage area in the internal storageunit. The already installed application program or data file to be savedmay be a program no longer needed or not used frequently. Then, it isnecessary to carry out an operation to add the new application programto the existing software by installing the program in the securedstorage area.

However, stress is much developed in the user by the fact that it isdifficult as well as cumbersome to carry out the work to form of ajudgment as to whether or not an already installed application programor data file is still required, the fact that it takes labor to carryout the work of deleting an existing application program or data file nolonger required or used infrequently and the fact that the work to set alocation for saving an application program or a data file and to set aconnection to the location is troublesome. It takes also much time tocarry out these works. The user's stress and the much time caused bythese works are a problem.

SUMMARY OF THE INVENTION

It is thus an object of the present invention addressing the problemsdescribed above to allow the user to utilize information such asapplication software and a data file, which are stored in internal andexternal storage units, by carrying out simple operations without beingaware of whether an area for storing information is the internal orexternal storage unit.

It is another object of the present invention addressing the problemsdescribed above to implement addition of application programs withoutrequiring the user to carry out excessive operations even if the memoryresource has a limited size.

It is a further object of the present invention addressing the problemsdescribed above to allow the user to utilize application software forallowing data files to be used without bearing an operation load.

To achieve the above object, according to a first aspect of the presentinvention, there is provided an information-processing apparatuscomprising: storage means for storing application programs and datafiles; calculating means for activating an application program stored inthe storage means to carry out predetermined processing; media drivemeans for recording and playing back information into and from anexternal recording medium; and control means which controls themedia-drive means and the storage means when the external recordingmedium for recording an application program is mounted on the mediadrive means so that: when the storage means includes a remaining freestorage area with a size large enough for accommodating the applicationprogram recorded in the external recording medium, the applicationprogram recorded in the external recording medium is installed in thestorage means; but when the storage means includes a remaining freestorage area with a size not large enough for accommodating theapplication program recorded in the external recording medium, on theother hand, an application program or a data file stored in the storagemeans is saved to the external recording medium in order to allocate afree storage area in the storage means and then the application programrecorded in the external recording medium is installed in the storagemeans.

According to a second aspect of the present invention, there is providedan information-processing method comprising: a judgment step ofverifying the size of a free storage area available in storage means andthe size of a storage area required for accommodating an applicationprogram loaded from an external recording medium into the storage meansand forming a judgment as to whether or not the application program canbe installed in the storage means; a save step of saving an applicationprogram or a data file stored in the storage means to the externalrecording medium in order to allocate a new free storage area in thestorage means in the case of outcome of the judgment step indicatingthat the application program cannot be installed in the storage means;and an installation step of installing the application program recordedin the external recording medium into the storage means having the newfree storage area allocated by the save step.

According to a third aspect of the present invention, there is providedan information-processing apparatus comprising: storage means;connection means for exchanging information between theinformation-processing apparatus and an external recording medium;calculating means for activating application software and carrying outprocessing based on the application software; and search means for firstsearching the storage means for a relevant data file to be used by theactivated application software, and for searching the external recordingmedium for the relevant data file through the connection means when thedata file is not found in the storage means.

According to a fourth aspect of the present invention, there is providedan information-processing method adopted by a calculating meansoperating in accordance with a predetermined step to search for adesired file related to processing of the predetermined step, theinformation-processing method comprising: a search step of searchingstorage means for the desired file; a connection step of setting aconnection to an external recording medium through connection means whenthe desired file is not found in the storage means; a search step ofsearching the external recording medium for the desired file after theconnection step is set.

According to a fifth aspect of the present invention, there is providedan information-processing apparatus comprising: storage means forstoring application software and data files; connection means forexchanging information between the information-processing apparatus andan external recording medium for storing application software and datafiles; recognition means for recognizing application software or datafiles, which are stored in the external recording medium connected tothe information-processing apparatus by the connection means; userinterface means for displaying application software or data files, whichare stored in the storage means, displaying application software or datafiles, which are stored in the external recording medium and recognizedby the recognition means, and for allowing a piece of the displayedapplication software to be selected for activation and for allowing oneof the displayed data files to be selected for use; and activationprocessing control means for loading application software from theexternal recording medium into the storage means and carrying outprocessing to activate the loaded application software in response to anoperation carried out on the user interface means to make a request foractivation of the application software.

According to a sixth aspect of the present invention, there is providedan information-processing method comprising: an activation-detectingstep of detecting an operation to activate application software; ajudgment step of forming a judgment as to whether application softwareto be activated which is detected by the activation-detecting step isstored in an storage means or an external recording medium; a loadingstep of loading application software from the external recording mediumin the case of result of the judgment step indicating that theapplication software is stored in the external recording medium; and anactivation step of activating application software loaded on the storagemeans by the loading step.

The above and other objects, features and advantages of the presentinvention will become apparent from the following description and theappended claims, taken in conjunction with the accompanying drawings inwhich like parts or elements denoted by like reference symbols.

BRIEF DESCRIPTION OF THE DRAWINGS

FIGS. 1A through 1D are diagrams showing a plan view, a right-side view,a left-side view and a top-side view of an information-processingapparatus implemented by an embodiment of the present invention;

FIG. 2 is a block diagram showing the internal configuration of theinformation-processing apparatus implemented by the embodiment;

FIG. 3 is an explanatory diagram showing the structure of an OSinstalled in the information-processing apparatus implemented by theembodiment;

FIG. 4 is an explanatory diagram showing the structure of a databasehandled in the information-processing apparatus implemented by theembodiment;

FIG. 5 is a diagram showing the plan view, the front view, the sideviews and the bottom view of an external appearance of a memory cardprovided by the embodiment;

FIG. 6 is an explanatory diagram showing the internal structure of thememory card provided by the embodiment;

FIG. 7 is an explanatory diagram showing a processing hierarchy of afile system provided by the embodiment;

FIGS. 8A through 8F are explanatory diagrams each showing a physicaldata structure of the memory card provided by the embodiment;

FIG. 9 is an explanatory diagram showing management flags of the memorycard provided by the embodiment;

FIGS. 10A and 10B are explanatory diagrams showing a data-updatingprocess carried out in the memory card provided by the embodiment aswell as concepts of physical and logical addresses in the memory cardprovided by the embodiment;

FIG. 11 is an explanatory diagram conceptually showing construction of alogical-address/physical-address transformation table provided by theembodiment;

FIGS. 12A and 12B are explanatory diagrams each showing a typicalstructure of the logical-address/physical-address transformation tableprovided by the embodiment;

FIG. 13 is an explanatory diagram showing relations between the flashmemory capacity of the memory card provided by the embodiment, thenumber of blocks per segment, a block size, a page size and the size ofthe logical-address/physical-address transformation table;

FIG. 14 is an explanatory diagram showing a typical structure ofdirectories stored in the memory card provided by the embodiment;

FIG. 15 is an explanatory diagram showing a management structure basedon a FAT (File Allocation Table) file system;

FIG. 16 is an explanatory diagram showing a model of a link managementstructure based on the FAT file system;

FIG. 17 is an explanatory diagram showing contents of a directory;

FIG. 18 is an explanatory diagram showing a typical structure ofsub-directories and files in a root directory;

FIG. 19 is an explanatory diagram showing the configuration of a serialinterface system between the memory card and the information-processingapparatus implemented by the embodiment;

FIG. 20 is an explanatory diagram showing a pattern of storage locationsof activated application software and data files to be referenced duringan operation of the application software in the embodiment;

FIG. 21 is a flowchart representing processing which is carried outafter the information-processing apparatus implemented by the embodimentis activated;

FIG. 22 shows a flowchart representing processing which is carried outwhen the user selects application software to be activated;

FIG. 23 is a flowchart representing processing which is carried out whena request for reference to a desired data file is made;

FIG. 24 is an explanatory diagram showing a server connected by acommunication network to the information-processing apparatusimplemented by the embodiment;

FIG. 25 is a flowchart representing processing to search storage unitsfor a data file;

FIG. 26 is an explanatory diagram showing an activation-history tableprovided by the embodiment;

FIG. 27 is an explanatory diagram showing how an application program isinstalled and saved in this embodiment;

FIG. 28 is an explanatory diagram showing how an application program isinstalled and saved in this embodiment;

FIG. 29 is an explanatory diagram showing how an application program isinstalled and saved in this embodiment;

FIG. 30 shows a flowchart representing processing carried out uponactivation of an application program at a time other than mounting ofthe memory card in this embodiment; and

FIG. 31 shows a flowchart representing processing which is carried outupon activation of an application program when a memory card is mountedon the information-processing apparatus in this embodiment.

PREFERRED EMBODIMENT OF THE INVENTION

A preferred embodiment of the present invention is explained in an ordergiven below. An information-processing apparatus implemented by theembodiment is an information-processing apparatus functioning as theso-called PDA (Personal Digital Assistant). Examples of the externalstorage apparatus are a memory card and a server connected to theinformation-processing apparatus by a communication network.

-   1: External Appearance of the Information-processing Apparatus-   2: Configuration of the information-processing apparatus-   3: Structures of the OS and the Database-   4: Memory Cards-   4-1: External Appearance-   4-2: Terminals and Internal Structure of the Memory Card-   4-3: Processing Hierarchy of the File System-   4-4: Physical Data Structure-   4-5: Concepts of the Physical Address and the Logical Address-   4-6: Logical-Address/Physical-Address Transformation Table-   4-7: Directory Structure-   5: FAT Structure-   6: Interface between the Memory Card and the Information-Processing    Apparatus-   7: Processing at Mounting of the Memory Card-   8: Activation of an Application Program and Reference to Data-   9: Typical Server Connected by a Communication Network-   10: File Search Processing    1: External Appearance of the Information-Processing Apparatus

FIGS. 1A through 1D are diagrams each showing a typical externalappearance of an information-processing apparatus 1 implemented by theembodiment.

The information-processing apparatus 1 is a compact, light and portableapparatus functioning as the so-called PDA. A memory card 70 to bedescribed later is mounted on the information-processing apparatus 1 asa recording medium. Data can be recorded and played back into and fromthe memory card 70.

It should be noted that the scope of the present invention is notlimited to a portable information-processing apparatus. Instead, thepresent invention can be applied to information-processing apparatusesof all types represented mainly by the personal computer. In addition,recording media used by the information-processing apparatus 1 forrecording data are not limited to the memory card 70. The recordingmedia include a variety of other recording media such as a magnetic discemployed in an HDD (Hard-Disc Drive), an optical disc, a magneto-opticaldisc, a RAM (Random-Access Memory) and a flash memory permanentlyinstalled in the information-processing apparatus 1.

FIGS. 1A, 1B, 1C and 1D are diagrams showing respectively a plan view, aright-side view, a left-side view and a top view of a typical externalappearance of the information-processing apparatus 1.

As shown in FIG. 1D, memory slots 7 are created on the top-surface sideof the information-processing apparatus 1. The memory slots 7 are eachused for mounting a memory card 70 on the information-processingapparatus 1. The information-processing apparatus 1 is capable ofrecording and playing back various kinds of data into and from a memorycard 70. The types of data includes computer data, music data, audiodata, moving-picture data, still-picture data and control data.

It should be noted that, in the information-processing apparatus 1 shownin FIGS. 1A through 1D, that 2 memory cards 70 can be mounted at thesame time on the 2 memory slots 7 respectively. It is needless to saythat the number of memory slots 7 does not have to be 2. It can be 1 or3 or greater.

On the front surface of the information-processing apparatus 1, adisplay unit 2 implemented by typically a liquid-crystal panel iscreated. The display unit 2 is used for displaying various kinds ofinformation such as pictures accompanying activation of applicationsoftware and accompanying various kinds of processing, data in the formof pictures and characters, information added to a playback audio signaland added to playback music, a guide message giving an instruction as tohow to carry out an operation and a menu screen for selecting playbackand edit operations or the like.

The information-processing apparatus 1 is provided with a variety ofoperators to be operated by the user. The operators include main memberssuch as operation keys 3 a, a jog dial 3 b and a push dial 3 c. The useris capable of carrying out a variety of necessary operations includingan operation to turn on the power supply, an operation to operate a menuand select an item from the menu and an operation to enter data such ascharacters by operating these operators.

These operation keys 3 a, the jog dial 3 b and the push dial 3 c are nomore than typical operators. To be more specific, the number ofoperators, the types of the operators and their locations can be changedin a variety of conceivable ways.

In addition, the information-processing apparatus 1 also includes aspeaker 4, a microphone 5 and an image-sensing unit 6. The speaker 4 isused for outputting a voice and/or a sound while the microphone 5 isused for inputting a voice and/or a sound. The image-sensing unit 6 isused for taking in an image-sensed picture.

Furthermore, a variety of terminals are provided for connecting theinformation-processing apparatus 1 to various kinds of equipment. Forexample, the terminals include a headphone terminal 10, a line-outputterminal 12 and a line-input terminal 11 as shown in FIG. 1B. Moreover,as shown in FIG. 1C, an IEEE-1394 terminal 8 and a USB (Universal SerialBus) terminal 9 are provided as well.

It should be noted that these terminals can have a variety ofconceivable types and be located at different possible locations. Thenumber of terminals may also vary from application to application.

For example, digital input/output terminals may also be provided foroptical cables. It is also possible to provide other terminals such asan SCSI (Small Computer System Interface) connector, a serial port or anRS232C connector.

In addition, in the case of this information-processing apparatus 1,information can be downloaded from a predetermined server or theInternet through a communication network such as a public network. Anantenna 13 provided in this information-processing apparatus 1 is usedfor establishing a radio communication with a base station of acommunication network.

2: Configuration of the Information-processing Apparatus

FIG. 2 is a diagram showing the internal configuration of theinformation-Processing apparatus 1.

As shown in the figure, the information-processing apparatus 1 includesinternal core members such as a system controller 21, a CPU (CentralProcessing Unit) 22, a flash ROM (Read-Only Memory) 23 and a D-RAM(Dynamic RAM) 24. In addition, the information-processing apparatus 1also includes an operation unit 35, a display control unit 27 and adisplay unit 2, which each serve as a basic interface with the user.

The system controller 21 inputs information on an operation from theoperation unit 35. Receiving the input, the system controller 21interrupts the CPU 22.

The operation unit 35 corresponds to the operation keys 3 a, the jogdial 3 b and the push dial 3 c, which are shown in FIGS. 1A through 1D.In addition, the display unit 2 also displays operation keys and icons.The displayed operation keys and icons are not described in theexplanation with reference to FIGS. 1A through 1D. The display unit 2also has a touch-detecting function using touch panel operators. In thiscase, the touch panel operators are included in the operation unit 35shown in FIG. 2.

The CPU 22 is a member that executes basic software called an OS(Operating System) and application programs.

The CPU 22 carries out necessary processing according to information onan operation. The information is supplied to the CPU 22 through thesystem controller 21.

The flash ROM 23 is used for storing a basic-operation program, avariety of processing constants and setting information among otherdata.

The D-RAM 24 is used for storing information required in various kindsof processing. The D-RAM 24 also serves as a data buffer and anextension of a work area of the CPU 22. In addition, the D-RAM 24 isused for a number of purposes in dependence on processing carried out bythe CPU 22. The D-RAM 24 includes a storage area which is a non-volatilearea. In this storage area, the OS and application software areinstalled.

The user invokes the application software installed in the D-RAM 24 bycarrying out an operation. Then, the CPU 22 executes the invokedapplication software.

The application software has a user-interface screen displayed byrendering a picture in a frame buffer allocated in the D-RAM 24. Thepicture rendering is based on a state transition triggered by a commandissued by the user.

The rendered-picture data is transferred to a display control unit 27 tobe eventually displayed on the display unit 2.

In addition, the memory slots 7 are created for memory cards 70 asdescribed earlier, allowing the memory cards 70 to be mounted on theinformation-processing apparatus 1. The CPU 22 is capable of making anaccess to any of the memory cards 70 through a memory-card interface 28in write and read operations. Interface operations between thememory-card interface 28 and the memory cards 70 will be describedlater.

The CPU 22 is capable of using any of the memory cards 70 mounted on thememory slots 7 as a memory-area extension.

In addition, it is needless to say that an application program stored inone of the memory cards 70 can be installed in the D-RAM 24. As analternative, by loading an application and data from one of the memorycards 70 into the D-RAM 24, necessary processing can be carried out.

Furthermore, by executing a desired application program, the CPU 22 iscapable of recording various kinds of data such as created text data,picture data, audio data and tabulated data into one of the memory cards70.

It should be noted that, when the information-processing apparatus 1detects an operation to mount a memory card 70 on one of the memoryslots 7, the information-processing apparatus 1 allows recording andplayback operations to be carried out on the memory card 70 or performsthe so-called hot plug-in operation wherein an application program anddata stored in the memory card 70 are automatically expanded in theD-RAM 24.

As an alternative, in a hot plug-in operation, when a memory card 70containing an application program and a data file is mounted on theinformation-processing apparatus 1, the CPU 22 installs the applicationprogram and the data file recorded in the memory card 70 into the D-RAM24, automatically activating the application program.

It should be noted that the information-processing apparatus 1implemented by this embodiment is not capable of activating anapplication program stored in a memory card 70 unless the program isexpanded in the CPU 22 first.

The memory-card interface 28 is capable of encoding data to be stored inthe memory card 70 and decoding data read out from the memory card 70.

The image-sensing unit 6 typically comprises a CCD image-sensing deviceand an image-sensing circuit system. Data of an image-sensed picturetaken by the image-sensing unit 6 can be stored in the D-RAM 24 by wayof an image-sensed-data interface 34. By execution of predeterminedapplication programs, the CPU 22 is capable of editing data of animage-sensed picture and recording the data into the memory card 70.

An audio interface 29 is an interface member for outputting data to thespeaker 4, the headphone terminal 10 and the line-output terminal 12 aswell as inputting data from the microphone 5 and the line-input terminal11.

For example, an analog audio signal input from the microphone 5 or theline-input terminal 11 is subjected to predetermined amplification andpredetermined filtering in an input-audio-processing unit 32. A signaloutput by the input-audio-processing unit 32 is converted by an A/Dconverter 33 into digital audio data, which is then supplied to theaudio interface 29. Controlled by the CPU 22, the audio interface 29processes the digital audio data received from the A/D converter 33.Typically, the digital audio data is subjected to a compression andencoding process in the audio interface 29. The audio interface 29outputs a result of the process to the memory-card interface 28 to berecorded in the memory card 70. On the other hand, the audio interface29 carries out a predetermined decoding process on digital audio dataread out and supplied from the memory card 70 and supplies a result ofdecoding to a D/A converter 30 for converting the digital audio datainto an analog audio signal. An output-audio-processing unit 31 carriesout predetermined processes such as amplification and impedanceadjustment, which conform to an output destination of the signal, on theanalog audio signal received from the D/A converter 30. The outputdestination of a signal produced by the output-audio processing unit 31can be the speaker 4, the headphone terminal 10 or the line-outputterminal 12.

A USB interface 25 is a communication interface for interfacing with anexternal apparatus connected to a USB connector 9. The CPU 22 is capableof communicating data with a personal computer connected externally oranother external apparatus such as a peripheral apparatus through theUSB interface 25. Examples of data communicated between the CPU 22 andan external apparatus through the USB interface 25 are applicationsoftware and a data file, which are handled in theinformation-processing apparatus 1. A data file contains typicallypicture data and audio data.

By the same token, an IEEE-1394 interface 26 is a communicationinterface for interfacing with an external apparatus connected to anIEEE-1394 connector 8. The CPU 22 is capable of communicating variouskinds of data with the external apparatus through the IEEE-1394interface 26.

A communication unit 36 is a member for communicating information withan external server, an Internet home page or the like through typicallya communication network to be described later by referring to FIG. 24.Particularly in the case of this embodiment, the information-processingapparatus 1 is capable of downloading application software and datafiles from typically an external server through the communication unit36.

The information-processing apparatus 1 implemented by this embodiment isexemplified as a radio communication terminal communicating with acommunication network. It should be noted, however, that theinformation-processing apparatus 1 can also be provided with a modem ora connection terminal connected to a public telephone network by a wire.

In addition, the information-processing apparatus 1 can be not onlyconnected by a public line to an external server or the like, from whichapplication software and data files can be downloaded, but alsoconnected to typically a server system or a terminal in a communicationsystem by a dedicated line.

It should be noted that the configuration of the information-processingapparatus 1 shown in FIG. 2 is typical to the bitter end. That is tosay, configurations of the information-processing apparatus 1 are notlimited to the one shown in the figure. For example, it is possible toadd a variety of configuration members employed generally in a personalcomputer or a PDA apparatus to the configuration, or eliminate memberseach serving as a component not actually needed from the configuration.

3: Structures of the OS and the Database

The following description explains the structure of an OS installed inthe information-processing apparatus 1 by referring to FIG. 3. As shownin FIG. 3, the OS which is basic software comprises a manager layerincluding a kernel serving as the nucleus of the OS, standard librariesand an HAL (Hardware Abstract Layer). The HAL is a layer of hardwaresuch as a control IC.

Application software is executed under basic operations of such an OSconfiguration.

A device driver or a plurality of device drivers are provided for theHAL, forming a layer. Each of the device drivers drives actual hardware(HW) with which the device driver is associated.

Particularly, in the case of the information-processing apparatus 1implemented by the embodiment, the memory card 70 can be driven by adevice driver. Since data stored in the memory card 70 is managed byusing a FAT (File Allocation Table) system as will be described later,the OS includes a FAT library. The OS also has an MS library forhandling memory cards 70.

Thus, a configuration for driving memory cards 70 comprises a FATlibrary, an MS library and a device driver known as a memory driver.

In the information-processing apparatus 1 implemented by the embodimentto have such an OS structure, a database concept is introduced as aconcept corresponding to what is normally called a file.

The technical term database used in this description is not what isnormally called a database used merely for storing data, but a databasewith a formatted structure wherein the database itself is capable ofmanaging data. In this meaning, the database corresponds to a file.

FIG. 4 is a diagram showing the structure of a database. As shown in thefigure, the database comprises a header (DTB header), a pointer tableand a data area for storing actual data. The DTB header includes adatabase name (DTB name) and an area for storing other information.Locations of pieces of actual data stored in the data area are managedby pointers stored in the pointer table.

There are 2 types of database with such a structure. For example, ingeneral, a piece of application software comprises a plurality of files,namely, an execution file named ***.exe and a data file named ***.data.A resource database named ***.prc corresponds to the execution file***.exe and a database database named ***.dtb corresponds to the datafile ***.data.

In the information-processing apparatus 1 implemented by thisembodiment, data is handled by adopting such a concept of database.Thus, a file recorded into or played back from a memory card 70 or afile handled by the FAT file system is treated as a database.

The technical term file used in this specification means a fileconforming to the general concept. In this embodiment, a file means adatabase with the structure described above.

4: Memory Cards

4-1: External Appearance

Next, the memory card 70 is explained. FIG. 5 is a diagram showing anexternal appearance of the memory card 70. The memory card 70 includes amemory device typically having a predetermined capacity in a case havinga planar shape like one shown in FIG. 5. In this embodiment, a flashmemory is used as the memory device.

FIG. 5 shows the plan view, the front view, the side view and the bottomview. The case is typically formed by adoption of a plastic moldingtechnique. As concrete typical dimensions, the case has a depth W11 of60 mm, a width W12 of 20 mm and a thickness W13 of 2.8 mm as shown inthe figure.

A terminal unit 72 has typically 10 electrodes provided on the lowerportion of the front surface, being oriented toward the bottom side ofthe case. Data is read out from and written into the memory deviceinside the case through the terminal unit 72. A cut 73 is provided onthe left upper portion of the case in a direction parallel to a planarsurface. The cut 73 prevents the memory card 70 from being insertedincorrectly when placing the memory card 70 on a mounting & dismountingmechanism of the drive main body. A label-sticking surface 74 is spreadfrom the top of the case to the bottom thereof, allowing the user tostick a label thereon. A slide switch 75 is provided on the bottom sidefor preventing data stored in the memory device from being inadvertentlydeleted.

In such a memory card 70, the capacity of the flash memory is prescribedto be 4 MB (mega bytes), 8 MB, 16 MB, 32 MB, 64 MB 128 MB.

The so-called FAT file system cited above is used as a file system forrecording and playing back data.

The write speed is set at a value in the range of 1,500 Kbyte/sec to 330Kbyte/sec and the read speed is set at 2.45 Mbyte/sec. The write unit isset at 512 bytes and the size of each deleted block is set at 8 KB or 16KB. The voltage of the power supply is set at a value in the range of2.7 V to 3.6 V and the maximum frequency of a serial clock signal SCLKis set at 20 MHz.

4-2: Terminals and Internal Structure of the Memory Card

FIG. 6 is a diagram showing the electrode structure of the terminal unit72. As shown in FIG. 5, the terminal unit 72 has a structure comprisingan array of 10 planar electrodes. The electrodes shown in FIG. 6, thatis, the terminals T1 to T10, are described as follows.

The terminals T1 and T10 are detected-voltage-Vss terminals. Theterminal T2 is an input terminal for receiving a serial protocol busstate signal BS. The terminals T3 and T9 are power-supply-voltage-Vccterminals. The terminal T4 is a data terminal serving as an input/outputterminal for inputting and outputting a serial protocol data signal. Theterminals T5 and T7 are each a reserved terminal. The terminal T6 is adetection terminal to detect mounting of a memory card on the drive, tobe more specific, on the memory-card interface 28 of theinformation-processing apparatus 1. The terminal T8 is an input terminalfor receiving a serial clock signal SCLK.

FIG. 6 also shows the internal configuration of the memory card 70. Asshown in the figure, the internal configuration of the memory card 70comprises a control IC 80 and a flash memory 81. The control IC 80 is amember for carrying out operations to read out data from and write datainto the flash memory 81.

As is obvious from the figure, a serial protocol bus state signal BS anda serial protocol clock signal SCLK are supplied to the control IC 80 byway of the terminal T2 and the terminal T8 respectively. In a writeoperation, the control IC 80 writes data supplied to the terminal T4into the flash memory 81 in accordance with the serial protocol busstate signal BS and the serial protocol clock signal SCLK. In a readoperation, on the other hand, the control IC 80 reads out data from theflash memory 81 in accordance with the serial protocol control bus statesignal BS and the serial protocol clock signal SCLK, supplying the datato the drive unit by way of the terminal T4.

A detection voltage Vss is supplied to a detection terminal T6. Thedrive unit detects the voltage appearing at the detection terminal T6through a resistor R as shown in the figure to form a judgment as towhether or not the memory card 70 has been placed on a mounting unit(the memory slot 7).

4-3: Processing Hierarchy of the File System

The following description explains a format in a system wherein thememory card 70 is used as a recording medium.

FIG. 7 is an explanatory diagram showing a processing hierarchy of afile system in a system using the memory card 70 as a recording medium.As shown in the figure, the processing hierarchy of the file systemcomprises an application processing layer on the top. The applicationprocessing layer is followed sequentially by a file managementprocessing layer, a logical-address management layer, a physical-addressmanagement layer and a flash-memory access layer. The file managementprocessing layer of the processing hierarchy is the so-called FAT (FileAllocation Table).

In addition, as is obvious from the figure, in the file system of thisembodiment, there are introduced logical-address and physical-addressconcepts to be described later.

4-4: Physical Data Structure

FIGS. 8A through 8F are explanatory diagrams each showing a physicaldata structure of the flash memory 81 which serves as a storage devicein the memory card 70.

A segment having a fixed size is a root data unit in the storage area ofthe flash memory 81. A segment is prescribed to have a size of 4 MB(Mega Byte) or 8 MB. The number of segments in the flash memory 81varies in dependence on the capacity of the flash memory 81.

As shown in FIG. 8A, 1 segment is divided into blocks which are each adata unit having a size of 8 KB (Kilo Byte) or 16 KB. As a rule, 1segment consists of 512 blocks. As shown in FIG. 8A, the last block inthe segment is block n where n=511. In the flash memory 81, however, anumber of blocks can be used as a defective area, that is, an area intowhich data cannot be written, provided that the number of blocks iswithin a predetermined allowable range. Thus, the number of trulyeffective blocks which data can be written into is smaller than 512 orn<511.

Let blocks 0 to n compose a segment as shown in FIG. 8A. The first 2blocks, namely, blocks 0 and 1, are boot blocks. In actuality, however,not all blocks 0 to n are valid. Since the boot blocks are the first 2of the valid blocks, the boot blocks are not necessarily guaranteed tobe blocks 0 and 1. The remaining blocks are user blocks used by the userfor storing user data.

As shown in FIG. 8D, 1 block is divided into pages 0 to m. As shown inFIG. 8E, a 1 page consists of a data area of 512 bytes and a redundantportion of 16 bytes. Thus, the size of 1 page is fixed at 528(=512+16)bytes. It should be noted that the structure of the redundant portionwill be described later by referring to FIG. 8F. The number of pages ina block with a size of 8 KB is 16 and the number of pages in a blockwith a size of 16 KB is 32.

The block structure shown in FIG. 8D and the page structure shown inFIG. 8E are applicable to all the boot blocks and all the user blocks,which are shown in FIG. 8A.

Data is read out from the flash memory 81 and written into the flashmemory 81 in page units. However, data is erased from the flash memory81 in block units. Data is always written into only a page which datathat has been erased from. Thus, in actuality, data can be written intoa block and data of a block can be updated.

As shown in FIG. 8B, the first one of the boot blocks includes a headerin page 0 and information on the position of initial bad data in page 1.Information on a position is referred to as an address. The first blockalso includes information called a CIS/IDS. As shown in FIG. 8C, thesecond one of the boot blocks contains a backup of information includedin the first one of the boot blocks.

The 16-byte redundant portion shown in FIG. 8E has a structure shown inFIG. 8F. As shown in FIG. 8F, the first bytes of the redundant portion,namely, bytes 0 to 3, are an overwrite area which can be rewritten independence on updating of data in the data area. Byte 0 of the overwritearea contains block status. Byte 1 contains data status called blockflag data. Predetermined high-order bits of Byte 2 is atransformation-table flag called page data status 1.

As a rule, information stored in bytes 3 to byte 15 is fixed datadepending on data of the page. That is to say, the information cannot bechanged. Byte 3 contains block information indicating, for example,whether or not the data of the page can be accessed and whether or notan operation to copy the data is inhibited. A 2-byte area consisting ofbytes 4 and 5 is a logical address to be described later. A 5-byte areaconsisting of bytes 6 to 10 is a reserved area of the format. A 2-bytearea consisting of bytes 11 and 12 is dispersed information ECC forimplementing error correction on the reserved area of the format. Theremaining area consisting of bytes 13 to 15 is data ECC for implementingerror correction on data stored in the data area shown in FIG. 8E.

Contents of bits 0 to 7 of byte 3 serving as a management flag in theredundant portion shown in FIG. 8F are defined as shown in FIG. 9. Firstof all, bits 7, 6, 1 and 0 are reserved or undefined. A value of 1 setas a flag in bit 5 indicates that a right to make an access to the blockis valid. That is to say, that the block is accessible or free. On theother hand, a value of 0 set as a flag in bit 5 indicates that a rightto make an access is invalid. That is to say, that the block isinaccessible or read-protected. A value of 1 set as a flag in bit 4indicates that a right to copy data of the block is valid. That is tosay, an operation to copy the data is OK. On the other hand, a value of0 set as a flag in bit 4 indicates that a right to copy the data isinvalid. That is to say, an operation to copy the data is NG.

Bit 3 is a transformation-table flag. This transformation-table flag isan identifier indicating whether or not the block is used for recordinga logical-address/physical-address transformation table to be describedlater. To be more specific, a value of 0 set in bit 3 indicates that theblock is used for recording a logical-address/physical-addresstransformation table. On the other hand, a value of 1 set in bit 3indicates invalidity, that is, the block is not used for recording alogical-address/physical-address transformation table.

Bit 2 is a system flag. A value of 1 set in the system flag indicatesthat the block is a user block. On the other hand, a value of 0 set inthe system flag indicates that the block is a boot block.

Relations among the segment, the block and the capacity of the flashmemory 81 are explained by referring to the 3 left columns of a tableshown in FIG. 13. As described earlier, the capacity of the flash memory81 in a memory card 70 is prescribed to be 4 MB, 8 MB, 16 MB, 32 MB, 64MB or 128 MB.

In the case of the smallest capacity of 4 MB, 1 block is prescribed tohave a size of 8 KB and the number of blocks per segment is 512. Thus,the flash memory 81's capacity of 4 MB is just equal to the size of 1segment. In the case of the capacity of 8 MB and the block size of 8 KB,the flash memory 81 comprises 2 segments which together consist of 1,024blocks. As described above, a block with a size of 8 KB consists of 16pages.

In the case of the capacity of 16 MB, however, 1 block can be prescribedto have a size of 8 KB or 16 KB. Thus, in the case of the block size of8 KB, a flash memory with the capacity of 16 MB consists of 2,048 blocksor 4 segments each consisting of 512 blocks. In the case of the blocksize of 16 KB, on the other hand, a flash memory with the capacity of 16MB consists of 21,024 blocks or 2 segments which together consist of1,024 blocks. As described above, a block with a size of 16 KB consistsof 32 pages.

In the case of the capacities of 32 MB, 64 MB and 128 MB, however, 1block can be prescribed to have a size of 16 KB only. Thus, a flashmemory with the capacity of 32 MB consists of 2,048 blocks or 4 segmentsand a flash memory with the capacity of 64 MB consists of 4,096 blocksor 8 segments. A flash memory with the capacity of 128 MB consists of8,192 blocks or 16 segments.

4-5: Concepts of the Physical Address and the Logical Address

On the basis of the physical data structure described earlier, conceptsof the physical address and the logical address in the file system ofthis embodiment are described by referring to operations to rewrite dataas shown in FIGS. 10A and 10B.

As shown in FIG. 10A, 4 blocks are extracted from a segment and used asa model in the following explanation.

A physical address is assigned to each of the blocks. A physical addressassigned to a block is a sequence number indicating the location of theblock in a physical array of the blocks. The relation between a blockand a physical address assigned to the block does not change. In theexample shown in FIG. 10A, physical addresses of 105, 106, 107 and 108are assigned respectively to the 4 blocks starting with the top one. Itshould be noted that an actual physical address occupies 2 bytes.

As shown in FIG. 10A, data is stored in blocks at the physical addressesof 105 and 106. On the other hand, blocks at the physical addresses of107 and 108 are unused blocks which no data is recorded in or data hasbeen deleted from.

A logical address is assigned to data stored in a block. A logicaladdress is an address used in the FAT file system to be described later.In the example shown in FIG. 10A, logical addresses of 102, 103, 104 and105 are assigned respectively to the 4 blocks starting with the top one.It should be noted that an actual logical address also occupies 2 bytes.

Assume that data stored at the physical address of 105 shown in FIG. 10Ais updated, that is, the data is rewritten or partially deleted. In thiscase, the file system of the flash memory 81 does not write new datainto the block at the physical address of 105, but into an unused block.That is to say, the data stored at the physical address of 105 isdeleted and the new data is stored in the block at the physical addressof 107 as shown in FIG. 10B in processing {circle around (1)}. The blockat the physical address of 107 was an unused block as shown in FIG. 10A.

In processing {circle around (2)} shown in FIG. 10B, the association ofthe logical addresses with the physical addresses is updated so that thelogical address of 102 associated so far with the physical address of105 as shown in FIG. 10A is now associated with the physical address of107 at which the new data is stored. As another result, the logicaladdress of 104 associated so far with the physical address of 107 asshown in FIG. 10A is now associated with the physical address of 105 asshown in FIG. 10B.

As is obvious from the above description, physical addresses are eachassigned uniquely to a block. On the other hand, a logical address canbe regarded as an address assigned uniquely to a piece of block datawhich can be stored temporarily in a block and moved later to anotherblock.

By swapping data among blocks as described above, operations to make anaccess to the same storage area or the same block can be prevented frombeing concentrated at the same storage area or the same block. Thus, itis possible to prolong the life of the flash memory 81 which has a limiton the number of permissible rewrite operations.

In addition, in spite of the fact that the location of a block ofpre-updating data is different from the location of a block ofpost-updating data, due to the processing {circle around (2)} to swap alogical address, from the FAT-system point of view, the pre-updatingdata and the post-updating data are stored at the same logical addressto which subsequent accesses can be made.

It should be noted that the swap processing is prescribed to swap alogical address among blocks pertaining to the same segment in order tosimplify control to update data in a logical-address/physical-addresstransformation table to be described later. Conversely speaking, alogical address is not to be swapped among blocks in different segmentsin the swap processing.

4-6: Logical-Address/Physical-address Transformation Table

As is obvious from FIGS. 10A and 10B, by carrying out processing to swapa logical address among blocks, the association of physical addresseswith logical addresses is changed. Thus, alogical-address/physical-address transformation table showing theassociation of physical addresses with logical addresses is required inmaking an access to the flash memory 81 in order to write or read outdata into or from the flash memory 81. That is to say, the FAT systemrefers to the logical-address/physical-address transformation table inorder to transform a logical address specified by the FAT system into aphysical address assigned to the logical address and allows an access tobe made to a block indicated by the physical address. Converselyspeaking, if such a logical-address/physical-address transformationtable does not exist, it will be impossible to make an access to theflash memory 81 by using the FAT system.

In the conventional information-processing apparatus, when the memorycard 70 is mounted on the drive main body, a microprocessor employed inthe drive main body checks data stored in the memory card 70 to create alogical-address/physical-address transformation table in the drive mainbody, and stores the table in a RAM employed in the drive main body.That is to say, the memory card 70 itself does not include alogical-address/physical-address transformation table. In the case ofthis embodiment, on the other hand, there is provided a configurationwherein a logical-address/physical-address transformation table isstored in the memory card 70 as will be described hereafter.

FIG. 11 is an explanatory diagram conceptually showing construction of alogical-address/physical-address transformation table stored in thememory card 70. As shown in the figure, alogical-address/physical-address transformation table is constructed soas to typically include sequentially increasing logical addresses eachassigned to a 2-byte physical address. It should be noted that, asdescribed earlier, every physical address and every logical address eachoccupy 2 bytes. A flash memory having a maximum capacity of 128 MBconsists of 8,192 blocks. An address having a width of 3 bytes has asufficient number of bits to be used for specifying all the flash memory8192 blocks of such a flash memory. For this reason, the physical andlogical addresses shown in FIG. 11 are each expressed by 2 bytes.

It should be noted, however, that the 2-byte address is expressed in thehexadecimal format consisting of a notation 0x followed by hexadecimaldigits. That is to say, the notation 0x indicates that the followingdigits are each a hexadecimal digit. It is also worth noting that thehexadecimal format consisting of the notation 0x followed by hexadecimaldigits is used in the following description to represent a hexadecimalnumber in the same way. In some figures, however, the notation 0x isomitted from the expression to make the hexadecimal expression simple.

FIGS. 12A and 12B are explanatory diagrams showing a typical structureof the logical-address/physical-address transformation table. Thestructure is based on the concept shown in FIG. 11. Thelogical-address/physical-address transformation table is stored in acertain block of the last segment of the flash memory 81 in a structureshown in FIGS. 12A and 12B.

First of all, as shown in FIG. 12A, 2 pages, namely, pages 0 and 1 ofpages composing the table, are an area allocated to alogical-address/physical-address transformation table of segment 0. Inthe case of a flash memory having a storage capacity of 4 MB, forexample, there is only 1 segment in the memory as is obvious from FIG.13. In this case, pages 0 and 1 are an area allocated to alogical-address/physical-address transformation table of this segment.

In the case of a flash memory having a storage capacity of 8 MB, on theother hand, there are 2 segments in the memory. In this case, pages 0and 1 are an area allocated to a logical-address/physical-addresstransformation table of segment 0 whereas the following 2 segments,namely, pages 2 and 3, are an area allocated to alogical-address/physical-address transformation table of segment 1.

With the storage capacity of the flash memory 81 increasing, theremaining pages in the block are an area allocated tological-address/physical-address transformation tables of the remainingsegments of the flash memory 81 in 2-page units. In the case of a flashmemory having a maximum capacity of 128 MB, there are 16 segments in thememory, pages up to segment 15 at the maximum are therefore allocated asan area of logical-address/physical-address transformation tables. Inthis case, 32 pages of the block are an area allocated tological-address/physical-address transformation tables of segments 0 tosegment 15 in 2-page units. As shown in FIG. 12A, pages 0 to N, whereN=31, are all used.

As is obvious from the above description, alogical-address/physical-address transformation table is created foreach segment.

FIG. 12B is a diagram showing the structure of alogical-address/physical-address transformation table created for asegment. As described above, the logical-address/physical-addresstransformation table occupies a 2-page data area. Since a 1-page dataarea comprises 512 bytes as shown in FIG. 8E, thelogical-address/physical-address transformation table shown in FIG. 12Boccupies 1,024(=512×2) bytes.

As shown in FIG. 12B, the 2-page data area consisting of 1,024 bytes isdivided into 2-byte units which are prescribed to be sequentiallyallocated to logical address 0, logical address 1 and so on, with thefirst 2-byte unit allocated to logical address 0. Bytes 991 and 992constituting a 2-byte unit are prescribed to be allocated to logicaladdress 495. A physical address to which a logical address is assignedis stored in a 2-byte unit allocated to the logical address. Thus, inthe logical-address/physical-address transformation table provided bythe present invention, in order to change the association of a logicaladdress with a physical address in typically processing of swapping thelogical address between blocks to accompany an operation to update data,the 2-byte unit allocated to the logical address is not changed but,instead, the contents of 2-byte unit are updated with a new physicaladdress to which the logical address is newly assigned.

The remaining 32 bytes, namely, byte 993 to the last byte 1,024, are anarea allocated to physical addresses of 16 redundant blocks. In thisway, the physical addresses of the 16 redundant blocks can be managed. Aredundant block is used typically as a work block as follows. In anoperation to swap data between 2 blocks, the data of the first block issaved temporarily in the work block. Then, the data of the second blockis transferred to the first block. Finally, the data saved in the workblock is transferred to the second block.

By the way, while 1 segment consists of 512 blocks as described earlier,the number of manageable blocks is only 496 as is obvious from logicaladdress 0 to logical address 495 shown in FIGS. 12A and 12B. This isbecause the remaining logical addresses are assigned to redundant blocksand, in the case of a flash memory, a certain number of blocks may beregarded as defective blocks (or unusable blocks or redundant blocks) asdescribed earlier. In actuality, there is indeed a considerable numberof defective blocks.

Thus, only 496 blocks can be managed as valid blocks or blocks whichdata can be written into and deleted from. These 496 blocks areconsidered to be sufficient.

Bit 3 of a management flag in a redundant portion of each page in ablock for storing the logical-address/physical-address transformationtable is set at 0. The management flag is shown in FIG. 9. A value of 0set in this bit 3 of the management flag indicates that the block isused for storing the logical-address/physical-address transformationtable.

The logical-address/physical-address transformation table is stored in ablock. When the contents of the logical-address/physical-addresstransformation table, that is, the contents of the block, are updated,the swap processing explained earlier by referring to FIGS. 10A and 10Bis carried out without exception much like other blocks for storinggeneral data. It is thus out of the bounds of possibility that the blockfor storing the logical-address/physical-address transformation tablebecomes indeterminate, and it is impossible to store thelogical-address/physical-address transformation table in a block locatedat a specific physical address.

When an access is made to the flash memory 81, the FAT system searchesthe blocks for one used for storing the logical-address/physical-addresstransformation table, that is, for one including a management flag withbit 3 set at 0 in each page. In order to make it easy for the FAT systemto search the blocks for the logical-address/physical-addresstransformation table, this embodiment is prescribed so that thelogical-address/physical-address transformation table is always storedin a block pertaining to the last segment of the flash memory 81. Thus,the FAT file system needs only to search the last segment of the flashmemory 81 for a block used for storing thelogical-address/physical-address transformation table. That is to say,in order to find the logical-address/physical-address transformationtable, it is not necessary to search all segments of the flash memory81.

The logical-address/physical-address transformation table shown in FIGS.12A and 12B is stored in the memory card 70 typically when the memorycard 70 is manufactured.

A relation between the capacity of a flash memory and the size of thelogical-address/physical-address transformation table is explained byreferring to FIG. 13.

As explained earlier by referring to FIGS. 12A and 12B, the size of alogical-address/physical-address transformation table for managing 1segment is the same as 2 pages which occupy 1,024 bytes or 1 KB. Thus,in the case of a flash memory having a storage capacity of 4 MB orconsisting of 1 segment, the size of thelogical-address/physical-address transformation table is 1 KB asindicated on the rightmost column of the table shown in FIG. 13. In thecase of a flash memory having a storage capacity of 8 MB or consistingof 2 segments, the size of the logical-address/physical-addresstransformation table is 2 KB, being equal to the size of 4 pages.

In the case of a flash memory having a storage capacity of 16 MB orconsisting of 2,048 blocks or 4 segments, the size of thelogical-address/physical-address transformation table is 4 KB, beingequal to the size of 8 pages. In the case of a flash memory having astorage capacity of 16 MB or consisting of 1,024 blocks or 2 segments,the size of the logical-address/physical-address transformation table is2 KB, being equal to the size of 4 pages.

In the case of a flash memory having a storage capacity of 32 MB orconsisting of 4 segments, the size of thelogical-address/physical-address transformation table is 4 KB, beingequal to the size of 8 pages. In the case of a flash memory having astorage capacity of 64 MB or consisting of 8 segments, the size of thelogical-address/physical-address transformation table is 8 KB, beingequal to the size of 16 pages. In the case of a flash memory having astorage capacity of 128 MB or consisting of 16 segments, the size of thelogical-address/physical-address transformation table is 16 KB, beingequal to the size of 32 pages.

4-7: Directory Structure

FIG. 14 is an explanatory diagram showing a typical structure ofdirectories stored in the memory card 70. Various kinds of main datathat can be handled by the memory card 70 include computer data,moving-picture data, still-picture data, message data, audio data andcontrol data. Thus, under a root directory in the directory structure,there are provided a message directory named VOICE, a still-picturedirectory named DCIM, a moving picture directory named MOxxxxnn, acontrol directory named CONTROL, an audio directory named HIFI andinformation-processing apparatus directory named PM.

Under each of the directories under the root directory, there areprovided sub-directories and files each called a data base as describedabove to form the so-called tree structure. It should be noted that, ofcourse, such a structure of directories is no more than a typicaldirectory structure. In actuality, a structure of directories is createdin accordance with a state of recording by the information-processingapparatus 1 and types of recorded files.

5: FAT Structure

As described in the explanation of the file-system hierarchy shown inFIG. 7, file management processing is carried out by using the FAT filesystem. To put in detail, in order for the information-processingapparatus 1 shown in FIG. 2 to implement operations to record and playback (or write and read out) data into and from the memory card 70, theFAT file system refers to a logical-address/physical-addresstransformation table in accordance with a request made in applicationprocessing and transforms a logical address into a physical address,making an actual access to the physical address in the memory card 70.In the following description, the structure of the FAT file system isexplained.

FIG. 15 is an explanatory diagram showing the outline of the managementstructure based on the FAT file system. It should be noted that, whilethe FAT structure shown in FIG. 15 and thelogical-address/physical-address transformation table are stored in thememory card 70, the FAT structure is a management structure stored inthe memory card 70 in this embodiment.

As shown in the figure, the FAT structure comprises a partition table,an empty area, a boot sector, a FAT, a FAT copy, a root directory and adata area.

The data area includes cluster 2, cluster 3 and so on. A cluster is adata unit used by the FAT file system as a management unit. In general,in the FAT file system, the standard size of a cluster is set at 4Kbyte. However, this cluster size can be changed to the number of powerof 2 in the range of 512 bytes to 32 Kbytes.

In the memory card 70 provided by this embodiment, the size of a blockis 8 Kbyte or 16 Kbyte as described above. In the case of a memory cardwith a block size of 8 Kbyte, the size of a cluster handled by the FATfile system is also 8 Kbyte. In the case of a memory card 70 with ablock size of 16 Kbyte, on the other hand, the size of a cluster handledby the FAT file system is also 16 Kbyte. That is to say, the size of 8Kbyte or 16 Kbyte is a data unit used in FAT management and a block sizeused as a data unit in the memory card 70. It should be noted that, fromthe memory-card point of view, the cluster size used in the FAT filesystem is equal to the size of each block in the memory card 70. Forthis reason, in the following description of this embodiment, a block isregarded to be equal in size as a cluster for the sake of simplicity.

On the left side of FIG. 15, block numbers x, - - - (x+m−1), (x+m),(x+m+1), (x+m+2) and so on are shown. Various kinds of data constitutingthe FAT structure are stored in the blocks to which the block numbersx, - - - (x+m−1), (x+m), (x+m+1), (x+m+2) and so on are assigned.

The partition table of the FAT structure includes the start and endaddresses of the FAT partition with a size not exceeding 2 Gbyte. TheFAT area is used for storing information on the FAT structure such as aFAT size, a cluster size and the size of each area for the so-called12-bit and 16-bit FAT file systems.

The FAT area is a table showing a link structure of clusters composingeach file as will be described later. The FAT area is followed by anarea for recording a copy of data stored in the FAT area.

The root directory includes a file name, a first-cluster number and anattribute for each file. The file name, the first-cluster number and theattribute for each file are stored in area with a size of 32 bytes.

In the FAT area, clusters are allocated to FAT entries on a 1-to-1basis. Each entry in a specific cluster includes a link destinationdescribing the number assigned to a cluster following the specificcluster. Assume that a file is stored in a plurality of clusters orblocks. In this case, the directory shows the number assigned to thefirst cluster. An entry of the first cluster in the FAT area shows anumber assigned to the second cluster and an entry of the second clusterin the FAT area shows a number assigned to the third cluster and so on.In this way, links of clusters are stored in the FAT area.

FIG. 16 is an explanatory diagram showing a model of the concept oflinks described above. Numbers shown in the figure are expressed in thehexadecimal format. Assume that there are 2 files, namely, MAIN.C andFUNC.C. In this case, the directory shows the first clusters of the 2files. Assume that numbers assigned to the 2 first clusters of the filesMAIN.C and FUNC.C are 002 and 004 respectively.

For the file MAIN.C, the entry for the first-cluster number of 002 showsa number of 003 assigned to the second cluster. The entry for thesecond-cluster number of 003 shows a number of 006 assigned to the nextcluster. The entry for the cluster number of 006 shows a number of FFFindicating that the cluster is the last cluster of the file MAIN.C.

In this way, the file MAIN.C is recorded in the memory card 70 in afirst cluster indicated by the number of 002, then a second clusterindicated by the number of 003 and then a last cluster indicated by thenumber of 006. Assume that the cluster numbers match block numbers inthe memory card 70. In this case, the file MAIN.C is stored in thememory card 70 in a first block indicated by the number of 002, then asecond block indicated by the number of 003 and then a last blockindicated by the number of 006. It should be noted, however, thatclusters are handled in the FAT file system by using logical addressesas described above. Thus, the logical addresses of clusters cannot beused as physical addresses of blocks as they are.

By the same token, the file FUNC.C is recorded by the FAT file system inthe memory card 70 in a first cluster indicated by the number of 004 andthen a last cluster indicated by the number of 005.

It should be noted that a cluster number of 000 shown in an entry of theFAT area indicates that the cluster associate with the entry correspondsto an unused block.

By the way, in addition to first-cluster numbers shown in FIG. 16, afile's directory stored in the root directory area also includestypically various kinds of data shown in FIG. 17 for the file.

As shown in FIG. 17, for each file, the directory includes the name ofthe file, an extension, an attribute, a change time, a change date andthe size of the file in addition to a number assigned to the firstcluster. Each number enclosed in parentheses for a piece of data is thenumber of bytes used for storing the piece of data.

A sub-directory cataloged as a subordinate to a directory is stored inthe data area instead of being stored in the root directory shown inFIG. 15. That is to say, each sub-directory is treated like a filehaving a directory structure. The size of a sub-directory is infinite.In addition, an entry to the sub-directory itself and an entry to theparent directory of the sub-directory are required.

FIG. 18 is an explanatory diagram showing a typical structure of theroot directory including a file named DIR1, another file named DIR2 anda further file named FILE. The file DIR1 has an attribute of directoryand is a sub-directory subordinate to the root directory. Likewise, thefile DIR2 has an attribute of directory and is a sub-directorysubordinate to the sub-directory DIR1. The file named FILE is includedin the sub-directory DIR2.

Thus, the root directory includes a number assigned to the first clusterof the file DIR1 which is a sub-directory. In the FAT area, a cluster Xis linked to a cluster Y which is linked to a cluster Z.

As is obvious from the figure, the sub-directories DIR1 and DIR2 areeach treated like a file and each include a FAT link.

6: Interface between the Memory Card and the Information-processingApparatus

FIG. 19 is an explanatory diagram showing the configuration of a serialinterface system between the memory card 70 and the memory-cardinterface 28 employed in the information-processing apparatus 1. Asshown in FIG. 19, the control IC 80 employed in the memory card 70comprises blocks including a flash-memory controller 80 a, a register 80b, a page buffer 80 c and a serial-interface 80 d.

The flash memory 81 controller 80 a transfers data between the flashmemory 81 and the page buffer 80 c on the basis of a parameter set inthe register 80 b. Data stored temporarily in the page buffer 80 c istransferred to the memory-card interface 28 employed in theinformation-processing apparatus 1 by way of the serial interface 80 d.On the other hand, data received from the memory-card interface 28employed in the information-processing apparatus 1 is buffered by thepage buffer 80 c through the serial interface 80 d.

The memory-card interface 28 has a structure for interfacing with thememory card 70. The structure includes a file manager 60, a transferprotocol interface 61 and a serial interface 62.

The file manager 60 manages files stored in the memory card 70. In thesystem implemented by this embodiment, for example, the memory card 70includes a stored management file for managing main-data files stored inthe memory card 70. The CPU 22 retrieves the management file from thememory card 70 mounted on the information-processing apparatus 1 anduses the file for creating the file manager 60. An access to the memorycard 70 is made through the file manager 60.

The transfer protocol interface 61 makes accesses to the register 80 band the page buffer 80 c.

The serial interface 62 prescribes protocols for transferring anyarbitrary data through 3 signal lines connecting the memory-cardinterface 28 to the memory card 70. The 3 signal lines are a SCLK(serial clock) line, a BS (bus state) line and an SDIO (serial datainput/output) line.

In operations carried out in the configuration described above, theinformation-processing apparatus 1 makes read and write accesses to theflash memory 81 employed in the memory card 70.

7: Processing at Mounting of the Memory Card

In the information-processing apparatus 1 described above, the userneeds to obtain required application software and install the softwarein the information-processing apparatus 1 as is the case with theordinary personal computer in order to have the information-processingapparatus 1 carry out desired information-processing operations.

In particular, in a hot plug-in operation described earlier, when amemory card 70 containing an application program and a data file ismounted on the information-processing apparatus 1, the CPU 22automatically installs the application program and the data filerecorded in the memory card 70 into the D-RAM 24, activating theapplication program. It is needless to say that an application programalready installed in the D-RAM 24 can be activated at an activationrequest made by the user by carrying out an operation. Hereinafter,installing and activating of an application program will be described.

First of all, a characteristic operation of this embodiment is describedin a simple and plain manner as follows. When the user activates anapplication program or switches the software from an application programto another, the OS functioning as basic software in the CPU 22 invokesthe application program and increments the contents of a counter for thenewly activated application program. The counter is included in anactivation-history table provided for all application programs. Theactivation-history table is stored in a non-volatile area of the D-RAM24. It should be noted that the activation-history table needs to bepreserved in the D-RAM 24 even if the power supply of theinformation-processing apparatus 1 is turned off. That is why theactivation-history table is stored in a non-volatile area of the D-RAM24.

The activation-history table has a typical configuration like one shownin FIG. 26. As is obvious from the figure, the number of applicationprograms, that is, the number of table entries, is determined by thesize of the activation-history table. Provided for each applicationprogram, a table entry includes an application-program ID, anapplication name, an activation count, a save flag, a temporaryattribute and an address.

The activation count represents the number of times the applicationprogram has been activated. The save flag indicates whether or not theapplication program has been saved in the memory card 70 in processingdescribed later. The temporary attribute is a flag indicating whether ornot the application program is a program temporarily installed in thememory card 70. The address indicates a location in the D-RAM 24 atwhich the application program is stored.

The activation count is the counter's contents which are incrementedwhen the application program is activated as described above.

When a memory card 70 is plugged into a memory slot 7, theinformation-processing apparatus 1 detects the plugging automaticallyand retrieves a driver program, an application program or data from thememory card 70, expanding the program or the data in the D-RAM 24. Thedriver program, the application program and the data are stored in thememory card 70 in advance.

If the size of a remaining storage area in the D-RAM 24 is smaller thanthe size of a program or the amount of data to be loaded from the memorycard 70, however, the program or the data cannot be newly installedunless an empty area is newly allocated in the D-RAM 24.

In order to solve this problem in this embodiment, the OS savesapplication programs and/or data files already loaded in the D-RAM 24 toan empty area in the memory card 70. The application programs and thedata files to be saved are selected by referring to theactivation-history table. The OS saves selected application programs andthe data files thereof sequentially one program after another, startingwith that used least frequently by the user until a free storage arealarge enough for accommodating a program or data to be newly loaded fromthe memory card 70 is allocated in the D-RAM 24.

It should be noted that the memory card 70 is assumed to have an emptyarea having a size at least equal to the total size of an applicationprogram and data to be installed in the D-RAM 24.

After application programs and the data files thereof stored in theD-RAM 24 are saved into the memory card 70 in the order of increasingfrequencies described above, a free storage area allowing an applicationprogram and/or data to be newly installed is allocated in the D-RAM 24.Then, the OS expands the application program and/or data stored inadvance in the memory card 70 into the D-RAM 24. The OS also adds anapplication-program ID, an application name, an activation count, a saveflag, a temporary attribute and an address as an entry for the installedapplication program to the activation-history table. The OS sets theactivation count as well as the temporary attribute at 1 and thenactivates the application program.

When the memory card 70 is taken out from the information-processingapparatus 1, that is, when the user carries out an operation to ejectthe memory card 70, the application program installed from the memorycard 70 as described above is uninstalled and application programs datafiles thereof saved from the D-RAM 24 to the memory card 70 as explainedabove are restored to the D-RAM 24. In this case, the OS actuallyuninstalls application programs each identified by a temporary attributeof 1 in the activation-history table. To be more specific, suchapplication programs are restored to the memory card 70. As describedabove, a temporary attribute of 1 assigned to an application programindicates that the application program was a program loaded from thememory card 70.

The OS restores application programs and their data files to the D-RAM24 by retrieving the programs and the data files thereof from the memorycard 70 and reloading them into the D-RAM 24 in the same state ofexpansion as before. At that time, the save flag assigned to each of therestored application programs in the activation-history table is resetto 0.

The above processing is further explained by referring to models shownin FIGS. 27, 28 and 29. First of all, assume that the D-RAM 24 is usedall but fully for storing application programs AP1, AP2 and AP3 as wellas data files DT1, DT2, DT3 and DT4 as shown in FIG. 27. At that time,let a memory card 70 used for recording an application program AP-a anda data file DT-a be inserted into a memory slot 7.

In this case, the hot plug-in function of the OS executed by the CPU 22makes an attempt to install the application program AP-a as well as thedata file DT-a from the memory card 70 and then activate the applicationprogram AP-a. In the D-RAM 24, however, there is no enough free storagearea left.

In order to solve this problem, the OS selectively saves applicationprograms sequentially one program after another, starting with that usedleast frequently by the user. Assume that the application program AP3has been used least frequently by the user. In this case, the OS savesthe application program AP3 and the data file DT3 thereof to an emptyarea in the memory card 70 as indicated by solid-line arrows in FIG. 27.

As a result, since empty areas are created in the D-RAM 24 as shown inFIG. 28, the application program AP-a and the data file DT-a thereof areinstalled into the empty areas in the D-RAM 24 as indicated bysolid-line arrows in the figure. FIG. 29 is a diagram showing the statesof the D-RAM 24 and the memory card 70, which are obtained after theapplication program AP-a and the data file DT-a thereof are installedinto the empty areas.

After the application program AP-a and the data file DT-a thereof areinstalled from the memory card 70 into the empty areas of the D-RAM 24,the CPU 22 activates the application program AP-a.

When the memory card 70 is ejected from the information-processingapparatus 1, on the other hand, the application program AP-a and thedata file DT-a thereof are first of all uninstalled, that is, restoredfrom the D-RAM 24 to the memory card 70 as shown by dashed-line arrowsin FIG. 29. As a result, since empty areas are created in the D-RAM 24as shown in FIG. 28, the application program AP3 and the data file DT3thereof are restored to the free storage areas in the D-RAM 24 asindicated by dashed-line arrows in the figure. The states of the D-RAM24 and the memory card 70, which are shown in FIG. 27, are obtainedafter the application program AP-a and the data file DT-a thereof arerestored to the memory card 70 and the application program AP3 and thedata file DT3 thereof are restored to the D-RAM 24. After these statesare established, the memory card 70 is ejected.

FIGS. 30 and 31 show flowcharts representing processing carried out bythe CPU 22 to implement the operations described above

To be more specific, FIG. 30 shows a flowchart representing processingcarried out upon activation of an application program at a time otherthan mounting of the memory card 70. That is to say, the processing iscarried out with no memory card 70 mounted or carried out at a timeafter an application program is installed from a mounted memory card 70and activated. In other words, execution of processing is not started bythe so-called hot plug-in function. In brief, the processing isprocessing to activate an ordinary application program.

As shown in FIG. 30, the flowchart begins with a step F201 to form ajudgment as to whether or not a command to activate a certainapplication program stored in the D-RAM 24 has been issued typically byan operation carried out by the user. If such a command has been issued,the flow of the processing goes on to a step F202 at which the CPU 22activates the application program and updates the activation-historytable. To put it in detail, the CPU 22 increments the activation-historytable's activation count assigned to the application program.

At the next step F203, the CPU 22 executes the application program tocarry out processing based on the program.

As described above, the activation-history table is updated atactivation of an application program. In this way, the CPU 22 is capableof always knowing an activation history of each application programstored in the D-RAM 24.

On the other hand, FIG. 31 shows a flowchart representing processingwhich is started by the so-called hot plug-in function at a time thememory card 70 is inserted into the memory slot 7. As shown in FIG. 31,the flowchart begins with a step F101 to form a judgment as to whetheror not insertion of the memory card 70 into the memory slot 7 has beendetected. If insertion of the memory card 70 into the memory slot 7 hasbeen detected, the flow of the processing goes on to a step F102 atwhich the CPU 22 finds the total size of an application program and adata file DT relevant thereto to be loaded from the memory card 70 aswell as finds the total size of free storage areas in the D-RAM 24. TheCPU 22 compares the total sizes with each other.

If the total size of an application program and a data file DT relevantthereto to be loaded from the memory card 70 is found not greater thanthe total size of free storage areas in the D-RAM 24, the flow of theprocessing goes on to a step F106 at which the application program andthe data file DT relevant thereto are loaded into the D-RAM 24 from thememory card 70.

At the next step F107, the activation-history table is updated for thenewly installed application program. To be more specific, a new entryfor the newly installed application program is created in theactivation-history table and the activation count as well as thetemporary attribute of the new entry are each set at 1.

At the next step F108, the CPU 22 executes the application program tocarry out processing based on the program.

If the result of the comparison at the step F102 indicates that thetotal size of an application program and a data file DT relevant theretoto be loaded from the memory card 70 is greater than the total size offree storage areas in the D-RAM 24, on the other hand, the flow of theprocessing goes on to a step F103 at which the CPU 22 searches theactivation-history table for an application program with a smallestactivation count.

At the next step F104, the application program with a smallestactivation count is saved to the memory card 70 and deleted from theD-RAM 24 to create a free storage area.

At the next step F105, the save flag for the saved application programin the activation-history table is set.

The flow of the processing then goes back to the step F102 at which theCPU 22 finds a new total size of free storage areas in the D-RAM 24 andcompares the new total sizes with the total size of an applicationprogram and a relevant data file DT, which are stored in the memory card70.

If the total size of an application program and a data file DT relevantthereto is found not greater than the total size of free storage areasin the D-RAM 24, the flow of the processing goes on to the step F106 torepeat the same pieces of processing of the step F106 and the subsequentsteps. If the total size of an application program and a data file DTrelevant thereto is found greater than the total size of free storageareas in the D-RAM 24, on the other hand, the flow of the processinggoes on to the step F103 at which pieces of processing of the step F103and the subsequent steps are carried out again. That is to say, the CPU22 searches the activation-history table for an application program witha smallest activation count, saves the application program from theD-RAM 24 to the memory card 70 and updates the activation-history tablebefore going back to the step F102.

It should be noted that, at the step F103, the activation-history tableis searched for an application program without a save flag.

As described above, if a free storage area with a sufficient size is notavailable in the D-RAM 24, the pieces of processing at the steps F102 toF105 are carried out repeatedly to sequentially save applicationprograms and data files DT relevant thereto in an order of increasingapplication counts, starting with an application program with a smallestapplication count till a free storage area with a sufficient size isallocated in the D-RAM 24.

As a free storage area with a sufficient size is secured in the D-RAM24, the flow of the processing goes on to a step F106 and the subsequentsteps at which an application program and a data file DT relevantthereto are loaded into the D-RAM 24 from the memory card 70, theactivation-history table is updated for the newly installed applicationprogram and the application program is executed to carry out processingbased on the program.

As described above, when the memory card 70 is mounted, an applicationprogram stored in the memory card 70 is automatically installed in theD-RAM 24 and executed. At that time, it is neither necessary for theuser to worry about the availability of a free storage area in the D-RAM24 nor necessary to carry out an operation to delete an applicationprogram from the D-RAM 24 or save an application program from the D-RAM24 to the memory card 70.

The above description does not include an explanation of processing thatcan be carried out by the user as long as the memory card 70 is mountedon the information-processing apparatus 1 and as long as an applicationprogram loaded from the memory card 70 remains installed in the D-RAM24. Examples of the processing include an operation carried out by theuser to halt the execution of the application program and an operationto re-invoke a temporarily suspended application program.

The flow of the processing then goes on to a step F109 to form ajudgment as to whether or not the user has carried out an operation toeject the memory card 70. If the user carried out an operation to ejectthe memory card 70, the flow of the processing goes on to a step F110.

At the step F110, the CPU 22 uninstalls application programs and theirdata files for which the temporary attributes are set. Applicationprograms and their data files for which the temporary attributes are setare application programs and data files loaded from the memory card 70.Uninstallation of an application program and a data file thereof meansrestoration of the application program and the data file thereof to thememory card 70 and their deletion from the D-RAM 24. The uninstallationresults in a free storage area in the D-RAM 24. Thus, the CPU 22 iscapable of restoring application programs and their data files for whichthe save flags are set to the D-RAM 24. Application programs and theirdata files for which the save flags are set are application programs anddata files saved to the memory card 70.

As the application programs and their data files are restored to theD-RAM 24, the save flags are reset. As a result, the D-RAM 24 isrestored to a state which existed before the memory card 70 was mountedon the information-processing apparatus 1.

By virtue of the processing carried out as described above, the user iscapable of using an application program without worrying about memoryresources offered by the D-RAM 24. As a result, there is exhibited aneffect of implementation of extremely comfortable operations developingno stress.

In addition, when a memory card 70 is mounted, an application program isinstalled and, when the memory card 70 is dismounted, the applicationprogram is uninstalled so that the D-RAM 24 is returned to a state priorto the mounting of the memory card 70. As a result, the user is allowedto carry out intuitive operations and enjoy noticeably improvedoperatability. In addition, since the user is capable of using anapplication program stored in the memory card 70 without being aware ofthe capacity and the status of the D-RAM 24 at all, the user is givennoticeably enhanced convenience.

Furthermore, since the activation-history table is updated and managedproperly each time an application program is activated, it is possibleto select an application program with a smallest activation count as aprogram to be moved and saved. Thus, it is possible to save anapplication program least likely activated with the memory card 70mounted on the information-processing apparatus 1. Thus, a conditionfavorable to the user can be implemented.

Moreover, the hot plug-in function automatically activates anapplication program when the application program is installed from thememory card 70 to the D-RAM 24. As a result, implementation of intuitiveoperations to be carried out by the user as well as easilycomprehensible operations can be further promoted.

8: Activation of an Application Program and Reference to Data

The following description explains characteristic operations of theinformation-processing apparatus 1 implemented by this embodiment, whichinclude activation of an application program and reference to data.

As described earlier, the information-processing apparatus 1 includesthe D-RAM 24 and the ROM 23. The D-RAM 24 and the ROM 23 serve as aninternal storage unit for storing application programs and data files.In addition, the memory card 70 is an external storage unit accessibleto the information-processing apparatus 1.

It should be noted that the communication unit 36 allows accesses to bemade to external servers and home pages through a communication network.Thus, these external servers can each be regarded as an external storageunit accessible to the information-processing apparatus 1. The externalservers and others will be explained later by referring to FIG. 24.

The user is capable of giving a command to the information-processingapparatus 1 to activate any application software in order to carry outprocessing based on the application software. It is needless to say thatthe user is allowed to verify and modify a variety of data filesreferred to by application software in the course of its operation.

Application software and data files can be stored in an internal storageunit such as the D-RAM 24 or an external storage unit such as the memorycard 70.

The information-processing apparatus 1 is not capable of executingapplication software stored in the external storage unit and making anaccess to a data file stored in the external storage unit unless thesoftware and the file are loaded into the internal storage unit first.That is to say, in order to use application software or a data filestored in the external storage unit of a conventional system such as theconventional information-processing apparatus, the user must load thesoftware and the file into the internal storage unit.

In the case of this embodiment, on the other hand, the user needs onlyto carry out an operation to invoke desired application software or toselect a data file to be referred without being aware of whether thesoftware and the file are stored in the external or internal storagefile. For the reason described above, the embodiment need to carry outoperations shown in FIG. 20 in a simple and plain manner.

FIG. 20 is an explanatory diagram showing a pattern of storage locationsof activated application software and data files to be referenced duringexecution of the application software.

Row {circle around (1)} shows a case in which application software to beactivated and a data file to be referenced are both stored in theinternal storage unit.

In this case, the CPU 22 carries out processing to normally activate theapplication software stored in the D-RAM 24. In order to reference thedata file during execution of the application software, the CPU 22retrieves the data file from the D-RAM 24 and supplies the data file toprocessing based on execution of the application software.

Row {circle around (2)} shows a case in which application software to beactivated is stored in the internal storage unit but a data file to bereferenced is stored in the external storage unit.

In this case, the CPU 22 carries out processing to normally activate theapplication software stored in the D-RAM 24. In order to reference thedata file during execution of the application software, the CPU 22 firstloads the data file from the memory card 70 into the D-RAM 24, thenretrieves the data file from the D-RAM 24 and, finally, supplies thedata file to processing based on execution of the application software.

Row {circle around (3)} shows a case in which application software to beactivated is stored in the external storage unit but a data file to bereferenced is stored in the internal storage unit.

In this case, in order to activate the application software, the CPU 22first loads the software from the memory card 70 into the D-RAM 24, andthen carries out processing to activate the software loaded in the D-RAM24. In order to reference the data file during execution of theapplication software, the CPU 22 retrieves the data file from the D-RAM24 and supplies the data file to processing based on execution of theapplication software.

Row {circle around (4)} shows a case in which application software to beactivated and a data file to be referenced are both stored in theexternal storage unit.

In this case, in order to activate the application software, the CPU 22first loads the software from the memory card 70 into the D-RAM 24, andthen carries out processing to activate the software loaded in the D-RAM24. In order to reference the data file during execution of theapplication software, the CPU 22 first loads the data file from thememory card 70 into the D-RAM 24, then retrieves the data file from theD-RAM 24 and, finally, supplies the data file to processing based onexecution of the application software.

That is to say, in the case of this embodiment, if application softwareto be activated and/or a data file to be referenced are stored in theexternal storage unit, the software is automatically loaded into theinternal storage unit to be executed and/or the data file is loaded intothe internal storage unit to be referenced at the time they are needed.In other words, it is not necessary for the user to carry out anoperation to transfer application software and/or a data file from theexternal storage unit such as the memory card 70 to the D-RAM 24 inadvance.

Processing carried out by the CPU 22 to execute the operations describedabove is explained by referring to flowcharts shown in FIGS. 21, 22 and23.

FIG. 21 is a flowchart representing processing which is carried outafter the information-processing apparatus 1 is activated. As shown inthe figure, the flowchart begins with a step F101 to form a judgment asto whether or not the user has turned on the power supply. As the userturns on the power supply, the CPU 22 goes on to a step F102.

At the step F102, the CPU 22 carries out an activation process torecognize usable application software and each usable data file, whichare stored in the D-RAM 24. When the activation process is completed,the flow of the processing goes on to a step F103 at which the usableapplication software is displayed on the display unit 2. At that time, alist of relevant data files can also be displayed as well.

The application software and the data files can be displayed in someformats such as a menu screen serving as an initial screen following theactivation process and a screen showing a list of selectable pieces ofapplication software and a list of selectable data files. As analternative, the application software and the data files can bedisplayed as icons as is the case with the ordinary personal computerand the so-called desk-top computer. Of course, other types of displayformats can be applied.

While the information-processing apparatus 1 is being activated, the CPU22 forms a judgment as to whether or not an external storage unit isconnected at the next step F104 and whether or not an external storageunit is disconnected at a step F105 in case no external storage unit isconnected. Typically, the CPU 22 forms a judgment as to whether or not amemory card 70 has been inserted into a memory slot 7 at the step F104and whether or not the memory card 70 has been pulled out from thememory slot 7 at the step F105. In the case of an external storage unitimplemented by an external server connected to theinformation-processing apparatus 1 by a communication network, the CPU22 forms a judgment as to whether or not a communication with the serverhas been established at the step F104 and whether or not thecommunication with the server has been terminated at the step F105.

If the outcome of the judgment formed at the step F104 indicates that anexternal storage unit is connected, the flow of the processing goes onto a step F106 at which the CPU 22 makes an access to the externalstorage unit to recognize application software and/or a data file. Atthe next step F107, the CPU 22 adds the recognized application softwareand/or the recognized data file to the list appearing on the displayunit 2. The flow of the processing then goes back to the step F103.

Typically, a memory card 70 is mounted on a memory slot 7 as an externalstorage unit. In this case, the CPU 22 loads the recognized applicationsoftware and/or the recognized data file from the memory card 70 intothe D-RAM 24, adding them to the list appearing on the display unit 2.

If the outcome of the judgment formed at the step F104 indicates that acommunication with an external server connected to theinformation-processing apparatus 1 by a communication network has beenestablished in the case of an external storage unit implemented by theserver, at the step F106, the CPU 22 recognizes application softwareand/or a data file which can be downloaded from the server. At the nextstep F107, the CPU 22 adds the recognized application software and/orthe recognized data file to the list appearing on the display unit 2.

If the outcome of the judgment formed at the step F105 indicates that anexternal storage unit has been disconnected, the flow of the processinggoes on to a step F108 at which the CPU 22 carries out processing todelete application software and/or a data file, which are stored in thedisconnected external storage unit, from the displayed list appearing onthe display unit 2. The flow of the processing then goes back to thestep F103.

To be more specific, when the memory card 70 is pulled off from thememory slot 7, application software and/or a data file, which are storedin the removed memory card 70, are erased from the displayed listappearing on the display unit 2.

In the case of an external storage unit implemented by an externalserver connected to the information-processing apparatus 1 by acommunication network, if a communication with an external server hasbeen terminated, application software and/or a data file which can bedownloaded from the server are erased from the displayed list appearingon the display unit 2.

It should be noted that, if a memory card 70 has been mounted by thetime the activation process is carried out at the step F102, asrecognition processing of the activation process, the CPU 22 recognizesapplication software and a data file, which are stored in the memorycard 70. At the next step F103, the CPU 22 adds the application softwareand the data file to a list displayed on the display unit 2.

In addition, at the step F108, application software and a data file,which have been loaded into the D-RAM 24 and used as valid software anda valid file, are not necessarily to be erased from the displayed listappearing on the display unit 2 by processing to be described later evenif they are stored in the removed external storage unit such as thememory card 70.

By carrying out the processing described above, application softwareand/or a data file are displayed on the display unit 2 on a timelymanner when the memory card 70 is mounted on the information-processingapparatus 1 or when a communication with an external server isestablished through a communication network. By the same token,application software and/or a data file are erased from a screenappearing on the display unit 2 on a timely manner when the memory card70 is dismounted from the information-processing apparatus 1, or when acommunication with an external server through a communication network isterminated.

Thus, the user is capable of recognizing application software and eachdata file, which are usable at the present time, in a simple mannerwithout being aware of whether the memory card 70 has been mounted ordismounted and aware of other status. To be more specific, the user iscapable of recognizing application software and each data file, whichare usable at the present time, without being aware of locations forstoring the application software and the data file.

At any time, when the user wants to activate a piece of applicationsoftware on the list appearing on the display unit 2, the user operatesthe operation unit 35 to select the piece of application software fromthe list.

FIG. 22 shows a flowchart representing processing which is carried outby the CPU 22 when the user selects application software to be activatedfrom a list appearing on the display unit 2.

As shown in the figure, the flowchart begins with a step F201 to form ajudgment as to whether or not the user has carried out an operation toactivate selected application software. If the user has carried out anoperation to activate selected application software, the flow of theprocessing goes on to a step F202 to form a judgment as to whether theselected application software to be activated is stored in the internalstorage unit such as the D-RAM 24 or stored in the external storage unitsuch as the memory card 70 or an external server.

If the selected application software to be activated is stored in theinternal storage unit, the flow of the processing goes on to a step F203at which the CPU 22 carries out processing to activate the softwaredirectly from the D-RAM 24.

If the selected application software to be activated is stored in theexternal storage unit, on the other hand, the flow of the processinggoes on to a step F204 at which the CPU 22 carries out processing toload the software from the memory card 70 to the D-RAM 24. To put it indetail, the CPU 22 makes an access to the memory card 70 through thememory-card interface 28, and then retrieves the application softwarefrom the memory card 70, loading it to the D-RAM 24. In the case of aserver serving as the external storage unit, the CPU 22 downloads theapplication software from the server to the D-RAM 24 by way of thecommunication unit 36.

At the next step F205, with the application software loaded in the D-RAM24, the CPU 22 activates the software.

FIG. 23 is a flowchart representing processing which is carried out bythe CPU 22 when a request for reference to a desired data file is made,for example, when application software makes a request for reference toa data file or when the user carries out an operation to select a datafile from a list appearing on the display unit 2.

As shown in the figure, the flowchart begins with a step F301 at whichthe CPU 22 forms a judgment as to whether or not a request for referenceto a data file has been made. If a request for reference to a data filehas been made, the flow of the processing goes on to a step F302 to forma judgment as to whether the requested data file is stored in theinternal storage unit such as the D-RAM 24 or stored in the externalstorage unit such as the memory card 70 or an external server.

If the requested data file is stored in the internal storage unit, theflow of the processing goes on to a step F303 at which the CPU 22retrieves the data file from the D-RAM 24 and supplies the file to theapplication software being executed.

If the requested data file is stored in the external storage unit, onthe other hand, the flow of the processing goes on to a step F304 atwhich the CPU 22 first of all carries out processing to load the file tothe D-RAM 24. To put it in detail, the CPU 22 makes an access to thememory card 70 through the memory-card interface 28, and then retrievesthe data file from the memory card 70, loading it to the D-RAM 24. Inthe case of an external server serving as the external storage unit, theCPU 22 downloads the data file from the server to the D-RAM 24 by way ofthe communication unit 36.

At the next step F305, with the data file loaded in the D-RAM 24, theCPU 22 retrieves the data file from the D-RAM 24 and supplies the fileto the application software being executed.

With the CPU 22 carrying out the pieces of processing represented by theflowcharts shown in FIGS. 21 to 23 as described above, the user onlyneeds to simply select application software to be activated and/or adata file to be referenced from a list appearing on the display unit 2without being aware of whether the application software and/or the datafile are stored in the internal or external storage unit. The user thusenjoys noticeably improved operatability.

It should be noted that the processing described above can be carriedout by the CPU 22 by execution of software at an OS or applicationlevel.

At the OS level, the processing is carried out by the CPU 22 inaccordance with information received from application software and/or auser interface as a program at the OS layer of the processing hierarchyexplained earlier by referring to FIG. 3.

As an alternative, it is also possible to create an application programto be executed by the CPU 22 for activation of desired applicationsoftware and reference to a data file. Such an activation/referenceapplication program can be put in a readily invokable state. That is tosay, when the user carries out an operation to activate certainapplication software or when a request for reference to a data file ismade, the activation/reference application program is executed toactivate desired application software or to reference a data file.

9: Typical Server Connected by a Communication Network

In the processing described above, an external server connected by acommunication network to the information-processing apparatus 1 as shownin FIG. 24 may serve as the external storage unit.

FIG. 24 is a diagram showing a model of a communication networkimplemented for a portable-telephone system or the like. Amobile-communication network N2 is a communication network provided by acommunication enterprise generally known as a provider. As shown in thefigure, the mobile-communication network N2 comprises a base station121, a relay station 122, an application server 123 and a gateway 124.

The information-processing apparatus 1 implemented by the embodimentestablishes radio communication with the base station 121 employed inthe mobile-communication network N2. It should be noted that there areof course a plurality of base stations 121 and a plurality of relaystations 122.

The application server 123 is a member for providing applicationsoftware and data files to the information-processing apparatus 1 andother terminals. The gateway 124 functions as a conversion unit forhandling data of typically home pages in the Internet N1. Thus, theapplication server 123 is capable of communicating with the Internet N1through the gate away 124. Information acquired from the Internet N1through such communication can be transmitted to a terminal such as theinformation-processing apparatus 1.

With such a mobile-communication network N2, the information-processingapparatus 1 is capable of downloading application software and datafiles from the application server 123 as well as application softwareand data files from the Internet N1.

The information-processing apparatus 1 treats the application server 123like an external storage unit, allowing application software executed bythe CPU 22 to use a necessary data file downloaded from the applicationserver 123.

With the application server 123 treated like an external storage unit asdescribed above, application software and/or a data file, which can bedownloaded from the application server 123, are displayed as a listappearing on the display unit 2 as long as the communication with theapplication server 123 is active. In addition, when the user carries outan operation to select the application software from the list, thesoftware is downloaded and activated. In this way, the user is capableof very easily utilizing application software and/or a data file, whichare provided by the application server 123.

10: File Search Processing

The following description explains search processing which is carriedout when application software activated in the information-processingapparatus 1 uses a data file also referred to as a database database.

As described earlier, the information-processing apparatus 1 includesthe D-RAM 24 and the ROM 23. The D-RAM 24 and the ROM 23 each serve asan internal storage unit for storing application programs and datafiles.

In addition, the memory card 70 is an external storage unit accessibleto the information-processing apparatus 1. It should be noted that thecommunication unit 36 allows accesses to be made to servers and homepages through a communication network. Thus, these servers shown in FIG.24 or the like can be regarded as an external storage unit accessible tothe information-processing apparatus 1.

The user is capable of giving a command to the information-processingapparatus 1 to activate any application software in order to carry outprocessing based on the application software. It is needless to say thatthe user is allowed to verify and modify a variety of data filesreferred to by application software in the course of its execution.

In processing based on application software, a relevant data file (or adatabase database) may be opened for use. In this case, searchprocessing represented by a flowchart shown in FIG. 25 is carried out byexecution of the OS or application software.

As shown in the figure, the flowchart begins with a step F101 to form ajudgment as to whether or not a request for a search for a data file hasbeen made. If a request for a search for a data file has been made, theflow of the processing goes on to a step F102 at which the D-RAM 24serving as an internal storage unit is searched for the data file. Theflow of the processing then goes on to a step F103 to form a judgment asto whether or not the data file is found. If the data file is found, theflow of the processing goes on to a step F111 at which the file isopened. At the next step F112, the application software is executed tocarry out processing using the data file.

If the outcome of the judgment formed at the step F103 indicates thatthe data file does not exist, on the other hand, the flow of theprocessing goes on to a step F104 to form a judgment as to whether ornot the memory card 70 has been plugged into the memory slot 7.

If the memory card 70 has been plugged into the memory slot 7, the flowof the processing goes on to a step F105 at which the memory card 70 issearched for the desired data file. At the next step F106, a judgment onthe existence of the data file is formed.

If the data file is found, the flow of the processing goes on to a stepF107 at which the file is loaded from the memory card 70 into the D-RAM24. Then, the flow of the processing goes on to a step F111 at which thefile is opened. At the next step F112, the application software isexecuted to carry out processing using the data file.

If the outcome of the judgment formed at the step F106 indicates thatthe data file does not exist or if the outcome of the judgment formed atthe step F104 indicates that no memory card 70 has been plugged into thememory slot 7, on the other hand, the flow of the processing goes on toa step F108 at which the communication unit 36 makes a communicationaccess to typically the application server 123 shown in FIG. 24 to makea request for a search for the desired data file. At the next step F109,a judgment on the existence of the data file is formed. If the data fileis found, the flow of the processing goes on to a step F110 at which thefile is downloaded from the application server 123 into the D-RAM 24employed in the information-processing apparatus 1. Then, the flow ofthe processing goes on to a step F111 at which the file is opened. Atthe next step F112, the application software is executed to carry outprocessing using the data file.

If the outcome of the judgment formed at the step F109 indicates thatthe data file does not exist, on the other hand, the flow of theprocessing goes on to a step F113 at which file-error processing iscarried out.

As described above, in this embodiment, if a request for a search for adesired data file is made, under control of application software or theOS, first of all, the internal storage unit is searched for the file. Ifthe desired data file is not found in the internal storage unit, thememory card 70 is searched for the file. If the desired data file is notfound in the memory card 70 either, an external server is searched forthe file.

Thus, it is possible to search a wide range of storage units for adesired data file and the user does not need to specify a storage unitto be searched for the file.

The above description explains the configuration of aninformation-processing apparatus implemented by this embodiment, atypical internal storage unit, a typical external storage unit andtypical processing related to application software and/or data files. Itshould be noted, however, that the scope of the present invention is notlimited to details of the information-processing apparatus, the storageunits and the processing. Instead, a variety of changes andmodifications can be made to the details. For example, the externalstorage unit can conceivably be portable recording media such as avariety of memory cards each having a type different from the memorycard 70, optical discs, magneto-optical discs and magnetic discs.

Furthermore, an external storage unit connected to theinformation-processing apparatus 1 by a communication line canconceivably be another so-called information apparatus connected to theinformation-processing apparatus 1 in addition to the external servershown in FIG. 24. For example, a personal computer or the like connectedto the information-processing apparatus 1 by an IEEE-1394 cable or anUSB cable can as a whole be regarded as an external storage unit.

In addition, the present invention can be applied to not only a portableinformation-processing apparatus, but also a broad range of otherapparatuses.

While a preferred embodiment of the present invention has been describedusing specific terms, such description is for illustrative purposesonly, and it is to be understood that changes and variations may be madewithout departing from the spirit or scope of the following claims.

1. An information-processing apparatus comprising: storage means forstoring application programs and data files; calculating means foractivating an application program stored in said storage means to carryout predetermined processing; media drive means for recording andplaying back information into and from an external recording medium,said media drive means including an application program; and controlmeans for controlling said media-drive means and said storage means whensaid external recording medium for recording an application program ismounted on said media drive means, wherein, when said storage meansincludes a remaining free storage area with a size large enough foraccommodating said application program in said external recordingmedium, said application program in said external recording medium isinstalled in said storage means, but when said storage means includes aremaining free storage area with a size not large enough foraccommodating said application program in said external recordingmedium, an application program and/or a data file stored in said storagemeans is saved to said external recording medium in order to allocateenough free storage area in said storage means to accommodate saidapplication program recorded in said external recording medium, and saidapplication program in said external recording medium is installed insaid storage means once there is enough free storage area in saidstorage means to accommodate said application program.
 2. Aninformation-processing apparatus according to claim 1, wherein saidinformation-processing apparatus further has an activation-historymanagement means for storing activation history information for eachapplication program on said storage means and for updating saidactivation history information for a specific application program uponactivation of said specific application program by said calculatingmeans, and said control means selects an application program to be savedto said external recording medium on the basis of said activationhistory information.
 3. An information-processing apparatus according toclaim 1 wherein said storage means is a non-volatile storage area.
 4. Aninformation-processing apparatus according to claim 1 wherein, when anapplication program or a data file has been saved in said externalrecording medium being dismounted from said media drive means, saidcontrol means controls said media-drive means and said storage means touninstall an application program installed from said external recordingmedium into said storage means in order to restore said installedapplication program to said external recording medium and to restoresaid application program or said data file saved in said externalrecording medium to said storage means.
 5. An information-processingapparatus according to claim 1 wherein said calculating means activatesan application program upon installation of said application programfrom said external recording medium into said storage means.
 6. Aninformation-processing method comprising: a judgment step of determiningthe size of a free storage area available in internal storage means ofan information processing apparatus and the size of a storage arearequired for accommodating an application program loaded from anexternal recording medium into said internal storage means anddetermining whether or not said application program can be installed insaid internal storage means; a save step of saving an applicationprogram and/or a data file stored in said internal storage means to saidexternal recording medium in order to allocate a new free storage areain said internal storage means when it is determined in said judgmentstep that said application program in said external recording mediumcannot be installed in said internal storage means; and an installationstep of installing said application program in said external recordingmedium into said internal storage means after said new free storage areahas been allocated in said internal storage means.
 7. Aninformation-processing method according to claim 6, wherein saidinformation-processing method further having an activation step ofactivating an application program upon installation of said applicationprogram from said external recording medium into said storage means bysaid installation step.
 8. An information-processing method according toclaim 6, wherein said information-processing method further has ahistory-updating step of updating activation history information for anapplication program upon activation of said application program, and anapplication program to be saved to said external recording medium isselected, in said save step, on the basis of said activation historyinformation.
 9. An information-processing method according to claim 6,wherein, when said application program or said data file has been savedin said external recording medium being dismounted, saidinformation-processing method further having a restoration step ofuninstalling an application program installed from said externalrecording medium into said storage means to restore said installedapplication program to said external recording medium and restoring anapplication program or a data file saved in said external recordingmedium to said storage means.
 10. An information-processing apparatuscomprising: internal storage means; connection means for exchanginginformation between said information-processing apparatus and anexternal recording medium; calculating means for activating applicationsoftware and carrying out processing based on said application software;search means for first searching said storage means for a relevant datafile to be used by said activated application software, and forsearching said external recording medium for said relevant data filethrough said connection means when said data file is not found in saidinternal storage means; and execution means for executing saidapplication software in said external recording medium when saidrelevant data file is found in said external recording medium, and forexecuting said application software in said internal storage means whensaid relevant data file is found in said internal storage means.
 11. Aninformation-processing apparatus according to claim 10 wherein saidexternal recording medium is a portable recording medium, and saidconnection means is implemented as a recording and playback unit forrecording and playing back data onto and from said portable recordingmedium.
 12. An information-processing apparatus according to claim 10wherein said external recording medium is an external server connectedto said information-processing apparatus by a wire or radiocommunication line, and said connection means is implemented as acommunication unit for communicating with said external server throughsaid communication line.
 13. An information-processing method adopted bya calculating means operating in accordance with a predetermined step tosearch for a desired file related to processing of said predeterminedstep, said information-processing method comprising: a search step ofsearching storage means for said desired file; a connection step ofsetting a connection to an external recording medium through connectionmeans when said desired file is not found in said internal storagemeans; a search step of searching said external recording medium forsaid desired file after said connection step is set; and an executionstep of executing said predetermined step in said external recordingmedium when said desired file is found in said external recordingmedium, and for executing said predetermined step in said internalstorage means when said desired file is found in said internal storagemeans.
 14. An information-processing method according to claim 13,wherein said external recording medium searched for said desired file,when said desired file is not found in said storage means, is a portablerecording medium, and said connection means allowing information to beinput from and output to said external recording medium is arecording/playback unit for recording and playing back data into andfrom said portable recording medium.
 15. An information-processingmethod according to claim 13, wherein said external recording mediumsearched for said desired file, when said desired file is not found insaid storage means, is an external server connected by a wire or radiocommunication line, and said connection means allowing information to beinput from and output to said external recording medium is acommunication unit for carrying out communications with said externalrecording medium through said communication line.
 16. Aninformation-processing apparatus comprising: internal storage means forstoring application software and data files; connection means forexchanging information between said information-processing apparatus andan external recording medium for storing application software and datafiles; recognition means for recognizing application software or datafiles, which are stored in said external recording medium connected tosaid information-processing apparatus by said connection means; userinterface means for displaying application software or data files, whichare stored in said internal storage means, displaying applicationsoftware or data files, which are stored in said external recordingmedium and recognized by said recognition means, and for allowing apiece of said displayed application software to be selected foractivation and for allowing one of said displayed data files to beselected for use; and activation processing control means for loadingapplication software from said external recording medium into saidinternal storage means and carrying out processing to activate saidloaded application software in response to an operation carried out onsaid user interface means to make a request for activation of saidapplication software.
 17. An information-processing apparatus accordingto claim 16, wherein said information-processing apparatus furtherhaving reference processing control means for loading a data file fromsaid external recording medium into said storage means and carrying outa process to reference said loaded data file in response to an operationcarried out on said user interface means, or for loading a data filerequired in the course of processing based on application software inexecution from said external recording medium into said storage meansand carrying out a process to reference said loaded data file, when arequest is made for reference of said data file.
 18. Aninformation-processing apparatus according to claim 16 wherein saidexternal recording medium is a portable recording medium, and saidconnection means is implemented as a recording and playback unit forrecording and playing back data onto and from said portable recordingmedium.
 19. An information-processing apparatus according to claim 16wherein said external recording medium is an external server connectedby a wire or radio communication line, and said connection means isimplemented as a communication unit for communicating with said externalserver through said communication line.
 20. An information-processingmethod comprising: an activation-detecting step of detecting anoperation to activate application software; a judgment step of forming ajudgment as to whether application software to be activated which isdetected by said activation-detecting step is stored in an internalstorage means or an external recording medium; a loading step of loadingapplication software from said external recording medium in the case ofresult of said judgment step indicating that said application softwareis stored in said external recording medium; and an activation step ofactivating application software loaded on said internal storage means bysaid loading step.
 21. An information-processing method according toclaim 20, wherein said information-processing method further having adata-file-referencing step of loading a data file from said externalrecording medium into said storage means and carrying out a process toreference said loaded data file in response to an operation carried outon said user interface means, or for loading a data file required in thecourse of processing based on application software in execution fromsaid external recording medium into said storage means and carrying outa process to reference said loaded data file, when a request is made forreference of said data file.
 22. An information-processing methodaccording to claim 20 wherein said external recording medium is aportable recording medium, and application software is played back fromsaid portable recording medium in said loading step.
 23. Aninformation-processing method according to claim 20 wherein saidexternal recording medium is an external server connected by a wire orradio communication line, and application software is downloaded fromsaid external server through said communication line in said loadingstep.